<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="../js/jq-1.12.4.js"></script>
</head>

<body>
    <div id="app"></div>
</body>
<script>
    function fn() {
        let a = {
            age: 10
        }
        let b = {
            name: "tom",
            "gender-1": "男",
            show() {
                console.log(this.age + "," + this.name + "," + this[gender - 1]);
            }
        }
        //b.show()
        //把b--->a中 for-in可以遍历对象和数组
        // for (let key in b) {
        //   a[key] = b[key]
        // }
        //a.show()

        $.extend(true, a, b, {
            weight: 45
        })
        console.log(a);
    }
    //jQuery让渡$符号
    jQuery(function ($) {
        console.log($ === jQuery)
        $("#app").css({
            "background-color": "red",
            "width": "100px",
            "height": "100px"
        })
    })
    let obj = jQuery.extend({}, {
        name: "tom"
    })
    console.log(obj)
</script>

</html>